public class Gem {
	
	public static enum GemType {yellow, orange, green, blue, purple, red, white, unknown, none};
	public static String[] gemTypeNames = new String[] {"yellow", "orange", "green", "blue", "purple", "red", "white", "unknown", "none"};
	
	public int x,y;
	public GemType type;
	
	public Gem(int _x, int _y, GemType _type) {
		x = _x;
		y = _y;
		type = _type;
	}
	
	public boolean equals(Object _gem) {
		Gem gem = (Gem) _gem;
		if(gem.x == x && gem.y == y && gem.type == type)
			return true;
		return false;
	}
	
	public String toString() {
		return Integer.toString(x) + "," + Integer.toString(y) + "," + gemTypeNames[type.ordinal()];
	}
}
